/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package se.bth.ke.firstfriend.util;

import org.pegdown.PegDownProcessor;

/**
 *
 * @author nico.rehwaldt
 */
public class Markdown {

    public static String toHTML(String markdown) {
        return getMarkdownParser().markdownToHtml(markdown);
    }
    
    /**
     * Returns a markdown parser to create the article html
     * @return
     */
    private static PegDownProcessor getMarkdownParser() {
        return new PegDownProcessor();
    }
}
